package com.template.core;

public class AttrBean {

	private String tableName;
	private String columnName;
	private String name;
	private String type;
	private String packageName;
	private boolean isPrimary;
	private boolean isFk;
	private boolean isPk;
	private String className;

	public AttrBean() {
		super();
	}

	public AttrBean(String name, String type) {
		super();
		this.name = name;
		this.type = type;
		this.isPrimary = false;
	}

	public AttrBean(String name, String type, boolean isPrimary) {
		super();
		this.name = name;
		this.type = type;
		this.isPrimary = true;
	}

	public String getAttrName() {
		return name.replaceFirst(name.substring(0, 1), name.substring(0, 1)
				.toUpperCase());
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getPackageName() {
		return packageName;
	}

	public void setPackageName(String packageName) {
		this.packageName = packageName;
	}

	public boolean isPrimary() {
		return isPrimary;
	}

	public void setPrimary(boolean isPrimary) {
		this.isPrimary = isPrimary;
	}

	public boolean isFk() {
		return isFk;
	}

	public void setFk(boolean isFk) {
		this.isFk = isFk;
	}

	public boolean isPk() {
		return isPk;
	}

	public void setPk(boolean isPk) {
		this.isPk = isPk;
	}

	public String getClassName() {
		return className;
	}

	public void setClassName(String className) {
		this.className = className;
	}

	public String getColumnName() {
		return columnName;
	}

	public void setColumnName(String columnName) {
		this.columnName = columnName;
	}

	public String getTableName() {
		return tableName;
	}

	public void setTableName(String tableName) {
		this.tableName = tableName;
	}
}
